package
{
	import sjd.controls.ITemplateInputRule
	
	public class TemplateInputRule1 implements ITemplateInputRule
	{
		public function validateChar(templateChar:String):Boolean{
			switch(templateChar){
				case "C":
					return true;
				case "c":
					return true;
				case "K":
					return true;
				default:
					return false;
			}
		}
		
		
		public function validateCharType(templateChar:String, inputChar:String):Boolean{
			var pattern:RegExp = /""/;
			switch(templateChar){
				case "C":
					pattern = /[A-N]/
					break;
				case "c":
					pattern = /[a-n]/
					break;
				case "K":
					pattern = /\d/
					break;
				default:
					pattern = /""/;
					break;
			}
			return pattern.test(inputChar);
		}
		
	}
}